cmake_minimum_required(VERSION 2.8.12)
project(reactor_client)
set(EXECUTABLE_OUTPUT_PATH ${CMAKE_CURRENT_SOURCE_DIR}/bin)
set(CXX_FLAGS
    -g
    -Wall
)
string(REPLACE ";" " " CMAKE_CXX_FLAGS "${CXX_FLAGS}")

MESSAGE(STATUS "operation system is ${CMAKE_SYSTEM_NAME}")

if(${CMAKE_SYSTEM_NAME} STREQUAL "CYGWIN")
    string(APPEND CMAKE_CXX_FLAGS " -std=gnu++11 -D_GNU_SOURCE=1 ")
else()
    string(APPEND CMAKE_CXX_FLAGS " -std=c++11 ")
endif()

set(CMAKE_CXX_FLAGS_DEBUG "-O0")
set(CMAKE_CXX_FLAGS_RELEASE "-O3 -DNDEBUG")

SET(CMAKE_BUILD_TYPE "$ENV{BUILD_TYPE}")
SET(CMAKE_USE_RELATIVE_PATHS "ON")
SET(CMAKE_CXX_COMPILER "g++")
SET(CMKAE_C_COMPILER "gcc")
SET(CMAKE_BUILD_TYPE Release)

include_directories(./include)
include_directories(./command_line_parser/include)
aux_source_directory(./source/ SRC_LIST)


add_executable(${PROJECT_NAME} ${SRC_LIST} main.cpp)
target_link_libraries(${PROJECT_NAME}
    pthread
)


